package steveshrader.budget.server.model;

import java.util.Date;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

@PersistenceCapable(identityType = IdentityType.APPLICATION)
public class Expense {
        @PrimaryKey
        @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
        private Long id;
        
        @Persistent
        private String userId;
        
        @Persistent
        private Date date;
        
        @Persistent
        private Integer amount;
        
        @Persistent
        private String vendor;
        
        @Persistent
        private String expenseType;
        
        @Persistent
        private String paymentType;

        public Expense(String userId, Date date, Integer amount, String vendor, String expenseType, String paymentType) {
                this.userId = userId;
                this.date = date;
                this.amount = amount;
                this.vendor = vendor;
                this.expenseType = expenseType;
                this.paymentType = paymentType;
        }
        
        public Date getDate() {
                return date;
        }

        public void setDate(Date date) {
                this.date = date;
        }

        public Integer getAmount() {
                return amount;
        }

        public void setAmount(Integer amount) {
                this.amount = amount;
        }

        public String getVendor() {
                return vendor;
        }

        public void setVendor(String vendor) {
                this.vendor = vendor;
        }

        public String getExpenseType() {
                return expenseType;
        }

        public void setExpenseType(String expenseType) {
                this.expenseType = expenseType;
        }

        public String getPaymentType() {
                return paymentType;
        }

        public void setPaymentType(String paymentType) {
                this.paymentType = paymentType;
        }

        public Long getId() {
                return id;
        }
        
        public String getUserId() {
                return userId;
        }
}